cmake_minimum_required(VERSION 3.10)
project(4y-ftv-cv LANGUAGES C CXX CUDA)

set(CMAKE_CXX_STANDARD 17)

message(STATUS "CUDA include path:${CMAKE_CUDA_TOOLKIT_INCLUDE_DIRECTORIES}")
include_directories(${CMAKE_CUDA_TOOLKIT_INCLUDE_DIRECTORIES})

#Gst Package
find_package(PkgConfig REQUIRED)

#OpenCV Package
find_package(OpenCV REQUIRED)
message(STATUS "OpenCV library status:")
message(STATUS "version:${OpenCV_VERSION}")
message(STATUS "libraries:${OpenCV_LIBS}")
message(STATUS "include path:${OpenCV_INCLUDE_DIRS}")
include_directories(${OpenCV_INCLUDE_DIRS})
find_package(OpenSSL REQUIRED)

include_directories(${CMAKE_CURRENT_SOURCE_DIR})

set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -g")
message(${CMAKE_CXX_FLAGS_RELEASE})

add_subdirectory(tracker4y)
add_subdirectory(init_project)

add_executable(demo demo.cpp)
target_link_libraries(demo tracker4y ${OpenCV_LIBS} OpenSSL::SSL OpenSSL::Crypto)

add_executable(initialize initialize.cpp)
target_link_libraries(initialize init OpenSSL::SSL OpenSSL::Crypto -lstdc++ -lm)
